<?php
 //得到get方式传递id
	$id = $_GET['id'];
	//引入配置文件
	require '../../public/config.php';
	//连接数据库
	$link = @mysqli_connect(HOST, USER, PWD);
	
	//判断是否成功
	if (!$link) {
		die('数据库连接失败');
	}
	//选择数据库
	mysqli_select_db($link, DB);
	//设置字符集
	mysqli_set_charset($link, CHAR);

	//准备sql语句
	$sql = "select * from user where id = $id";
	//发送sql
	$result = mysqli_query($link, $sql);
	//得到该条数据
	$info = mysqli_fetch_assoc($result);
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>ECSHOP 管理中心 - 编辑商品 </title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link href="../include/Css/general.css" rel="stylesheet" type="text/css" />
<link href="../include/Css/main.css" rel="stylesheet" type="text/css" />
</head>
<body>
<h1>
    <span class="action-span"><a href="./usersList">商品列表</a>
    </span>
    <span class="action-span1"><a href="__GROUP__">ECSHOP 管理中心</a></span>
    <span id="search_id" class="action-span1"> - 编辑商品 </span>
    <div style="clear:both"></div>
</h1>

<div class="tab-div">
    <div id="tabbar-div">
        <p>
            <span class="tab-front" id="general-tab">通用信息</span>
        </p>
    </div>
    <div id="tabbody-div">
        <form enctype="multipart/form-data" action="action.php?a=pass" method="post">
		<input type="hidden" name="id" value="<?php echo $id?>" />
           <table width="90%" id="general-table" align="center">
                <tr>
                    <td class="label">会员名称：</td>
                    <td><input type="text" name="username" value="<?php echo $info['username']?>" />
                    <span class="require-field">*</span></td>
                </tr>
                   
                <tr>
                    <td class="label">新密码： </td>
                    <td>
                        <input type="password" name="pass" value=""/>
                        </span>
                    </td>
                </tr>


            </table>
            <div class="button-div">
                <input type="submit" value=" 确定 " class="button"/>
                <input type="reset" value=" 重置 " class="button" />
            </div>
        </form>
    </div>
</div>

<div id="footer">
共执行 9 个查询，用时 0.025161 秒，Gzip 已禁用，内存占用 3.258 MB<br />
版权所有 &copy; 2005-2012 上海商派网络科技有限公司，并保留所有权利。</div>
</body>
</html>